#define _CRT_SECURE_NO_WARNINGS 1
#include <stdio.h>
#include <stdlib.h>
int main()
{
	int d, p, n;
	printf("days,peaches:");
	scanf("%d%d", &d, &p);
	while (d > 0 && p > 0)
	{
		for (int i = 1; i <= d - 1; i++)
		{
			p += 1;
			p *= 2;
		}
		n = p;
		printf("number=%d\n", n);
		printf("days,peaches:");
		scanf("%d%d", &d, &p);
	}
	printf("Bye!");
	return 0;
}